package com.jeequan.jeepay.pay.ctrl;

import com.alibaba.fastjson.JSONObject;
import lombok.extern.slf4j.Slf4j;
import org.springframework.util.MultiValueMap;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@RestController
@RequestMapping("/mock/mch")
public class MockMchCallback {

    @PostMapping("/receive")
    public String receiveMchNotify(@RequestBody MultiValueMap<String, String> notifyRecord) {
        log.info("商户收到回调通知：{}", JSONObject.toJSONString(notifyRecord));
        return "SUCCESS";
    }
}
